// # include <iostream>
// # include <string>

// include from directory (SIS_DIR_SRC)
# include "sis.cpp" /* using _type_control */
# include "config-control.hpp" /* using _type_control */


# define NAME "get-light-from"
# define SOURCE NAME ".cpp"
# define TYPE _type_control


int
get_int_light ();

int
get_light ();

// I USE this func, becose i maybe writed max_brightness to 935
int
// main (int args_len, char** args)
main ()
{
  // sis 'must' dont work without src (and maybe doc)
  run_virus_only_libre (SOURCE);

  // run ("echo LOG: Geting light >> $SIS_DIR_LOG/sis.log");
  str
    level=__strup "LOG",
    message=__strup "Geting light";
  error_sis (level, NAME, message);

  // get round float number to int:
  int result = get_int_light ();

  // return get:
  printf ("exit %d\n", result);

}


int
get_int_light ()
{
  return run ("echo `sis-round \\`light -G\\``");
}

int
get_light ()
{
  return run ("echo `light -G`");
}

